<?php
Doo::loadCore('db/DooModel');

class FrbFlatVilleBase extends DooModel
{

    /**
     * @var int Max length is 11.
     */
    public $vil_id;

    /**
     * @var varchar Max length is 60.
     */
    public $vil_nom;

    /**
     * @var varchar Max length is 6.
     */
    public $vil_cp;

    public $_table = 'frbFlat_ville';
    public $_primarykey = 'vil_id';
    public $_fields = array('vil_id','vil_nom','vil_cp');

    public function getVRules() {
        return array(
                'vil_id' => array(
                        array( 'integer' ),
                        array( 'maxlength', 11 ),
                        array( 'optional' ),
                ),

                'vil_nom' => array(
                        array( 'maxlength', 60 ),
                        array( 'notnull' ),
                ),

                'vil_cp' => array(
                        array( 'maxlength', 6 ),
                        array( 'notnull' ),
                )
            );
    }

}